<?php
//
use think\facade\Route;
//
////
////路由
//Route::get('router/lists$', 'admin/Route/index');      //列表
//Route::post('router', 'admin/Route/insert');
//Route::put('router', 'admin/Route/update');
//Route::post('router/status$', 'admin/Route/status');
//Route::get('router', 'admin/Route/detail');
Route::get('test', 'admin/Test/index');
Route::get('testA', 'admin/Test/test');
//Route::get('bind', 'admin/Test/bind');

$result = (new \app\admin\model\Route())->getAdminModelCache('set');

foreach ($result as $k=> $v){
    //rule 不为空的
    if(!empty($v['rule']) and !empty($v['method'])){
        Route::rule($v['rule'], $v['route'], $v['method']);
//    dump('Route::rule('.$v['rule'].', '.$v['route'].','. $v['method'].');');
    }
}
//die;


